package com.leyu.mall.service.mdm.impl;

 

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.leyu.mall.dao.mdm.MDMProvinceMapper;
import com.leyu.mall.domain.mdm.MDMProvince;
import com.leyu.mall.service.mdm.IMDMProvinceService;
@Service
@Transactional(rollbackFor = Exception.class)
public class MDMProvinceServiceImpl implements IMDMProvinceService 
{
	
	@Resource
	private MDMProvinceMapper mdmProvinceMapper;
	
	
	
	public List<MDMProvince> getAllMDMProvince() throws Exception{
		
		return this.mdmProvinceMapper.getAllProvince();
		 
	}

	public MDMProvince getMDMProvinceById(Long provinceId) throws Exception{
		return this.mdmProvinceMapper.getMDMProvinceById(provinceId);
		
		
	}

	public void deleteMDMProvince(Long provinceId) throws Exception{
		
		this.mdmProvinceMapper.deleteMDMProvince(provinceId);
		
	}
	
	public void save(MDMProvince entity) throws Exception{
		this.mdmProvinceMapper.addMDMProvince(entity);
		
	}

 
}